<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="../include/head.jspf"%>  

<head>
<title>东方易云后台管理系统</title>

<script language="javascript">
function goPage(pageNo) {
	document.goPageForm.pageNo.value = pageNo;
	document.goPageForm.submit();
}
</script>

</head>
<body>
<form id="changeGroupForm" action="/group/${type}/list"  method="post">

				组名称： <input  id ="groupNameSearch" name="groupNameSearch"  value="<c:out value='${groupNameSearch}'/>"/>
				
				机构名称：<SELECT ID="organizationIdSearch" SIZE="1"  name="organizationIdSearch">
							<option value="">全部</option>
							<c:forEach var="organizationVO" items="${organizationVOList}" varStatus="oStatus">
								<OPTION VALUE="<c:out value='${organizationVO.organizationId}'/>" <c:if test="${organizationVO.organizationId eq organizationIdSearch}">selected</c:if> ><c:out value='${organizationVO.chineseName}'/></OPTION>
							</c:forEach> 
					</SELECT>
				 组状态：启用：<input name="statusSearch" type="radio" value="1" <c:if test="${statusSearch eq statusOne}">checked</c:if> /> 停用：<input name="statusSearch" type="radio"  value="0" <c:if test="${statusSearch eq statusZero}">checked</c:if>/>
				 
				<input value="查&nbsp;&nbsp;询" type="submit"/>
			
<br/>
<br/>
<a href="/group/${type}/add">增加</a>
<table border="1">
	<tr>
	<td>序号</td>
	<td> 组名称</td>
	<td> 机构名称 </td>
	<td>是否为管理员组 </td>
	<td>组状态 </td>
	<td>创建时间 </td>
	<td>更新时间 </td>
	<td>操作</td>
	</tr>
	<c:forEach var="groupInfoBean" items="${groupInfoBeanList}" varStatus="vStatus">
		<tr>
		<td>${vStatus.count+(pageNo-1)*recordCountInOnePage}</td>
		<td><c:out value='${groupInfoBean.groupInfoVO.groupName}'/></td>
		<td>
			<c:choose>
				<c:when test="${siteLanguage eq 'zh_CN'}"><c:out value='${groupInfoBean.organizationVO.chineseName}'/></c:when>
				<c:otherwise><c:out value='${groupInfoBean.organizationVO.englishName}'/></c:otherwise>
			</c:choose>
		</td>
		<td><c:out value='${adminFlagMap[groupInfoBean.groupInfoVO.adminFlag]}'/></td>
		<td><c:out value='${statusMap[groupInfoBean.groupInfoVO.status]}'/></td>
		<td><fmt:formatDate value="${groupInfoBean.groupInfoVO.createDate}" type="both"  pattern="yyyy-MM-dd HH:mm:ss" /></td>
		<td><fmt:formatDate value="${groupInfoBean.groupInfoVO.updateDate}" type="both"  pattern="yyyy-MM-dd HH:mm:ss" /></td>
		<td><a  href="/group/${type}/edit?groupId=<c:out value='${groupInfoBean.groupInfoVO.groupId}'/>&pageNo=<c:out value='${pageNo}'/>&groupNameSearch=<c:out value='${groupNameSearch}'/>&organizationIdSearch=<c:out value='${organizationIdSearch}'/>&statusSearch=<c:out value='${statusSearch}'/>">修改</a>||
		    <a href="/group//${type}/control?groupId=<c:out value='${groupInfoBean.groupInfoVO.groupId}'/>&status=<c:out value='${groupInfoBean.groupInfoVO.status eq statusZero ? statusOne:statusZero}'/>&pageNo=<c:out value='${pageNo}'/>&groupNameSearch=<c:out value='${groupNameSearch}'/>&organizationIdSearch=<c:out value='${organizationIdSearch}'/>&statusSearch=<c:out value='${statusSearch}'/>"><c:out value='${statusMap[groupInfoBean.groupInfoVO.status eq statusZero ? statusOne:statusZero]}'/></a></td>
		</tr>
	
	</c:forEach>


</table>


</form>

	
	<c:out value="${pageInfo}" escapeXml="false"></c:out>

<form method="post" action="/group/${type}/list" id="goPageForm" name="goPageForm">
      <input type="hidden" name="pageNo" value="<c:out value='${pageNo}'/>" />
      <input type="hidden" id="groupNameSearch" name="groupNameSearch" value="<c:out value='${groupNameSearch }' />">
      <input type="hidden" id="organizationIdSearch" name="organizationIdSearch" value="<c:out value='${organizationIdSearch }' />">
      <input type="hidden" id="statusSearch" name="statusSearch" value="<c:out value='${statusSearch }' />">
</form>
</body>

</html>
